package com.efast.dmom.mgmt.service.master.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.efast.dmom.mgmt.dao.master.TmBasBomDao;
import com.efast.dmom.mgmt.entity.master.TmBasBom;
import com.efast.dmom.mgmt.service.master.TmBasBomService;

/**
 * <p>
 * bill of material 服务实现类
 * </p>
 *
 * @author Xu Cong
 * @since 2018-09-19
 */
@Service
public class TmBasBomServiceImpl extends ServiceImpl<TmBasBomDao, TmBasBom> implements TmBasBomService {

	@Autowired
	TmBasBomDao bomDao;

	@Override
	public void deleteBom(int bomId) {

		bomDao.deleteBom(bomId);
		deleteBomItem(bomId);
	}

	@Override
	public void deleteBomItem(int bomId) {

		bomDao.deleteBomItemByBomId(bomId);
	}
}
